package cn.bob.basic.mapper;

import cn.bob.basic.query.BaseQuery;
import org.springframework.context.annotation.Primary;

import java.util.List;

/**
 * @author bob
 * @data 2022/10/10-16:04
 */
public interface IBaseMapper<T> {
    //添加
    void add(T t);

    //删除
    void delById(Long id);

    //批量删除
    void batchDel(List<Long> ids);

    //修改
    void update(T t);

    //查询所有
    List<T> findAll();

    //查询单条
    T findById(Long id);

    //总查询所有的count
    Integer queryByCount(BaseQuery query);

    //分页查询
    List<T> queryByPage(BaseQuery query);


}
